from dataaccess import PlayData
from common import utility


class PlayBiz(object):
    def __init__(self):
        pass

    def __ValidateInsert(self, play):
        valid = True
        if not valid:
            raise utility.BusinessException(message="",fieldName = "")
        
    def __ValidateUpdate(self, play):
        valid = True
        if not valid:
            raise utility.BusinessException(message="",fieldName = "")
        
    def __ValidateDelete(self, dj,songID):
        valid = True
        if not valid:
            raise utility.BusinessException(message="",fieldName = "")
        
    def InsertPlay(self, play):
        self.__ValidateInsert(play)
        playData = PlayData.PlayData()
        playData.InsertPlay(play)

    def UpdatePlay(self, play):
        self.__ValidateUpdate(play)
        playData = PlayData.PlayData()
        playData.UpdatePlay(play)

    def DeletePlay(self, dj,songID):
        self.__ValidateDelete(dj,songID)
        playData = PlayData.PlayData()
        playData.DeletePlay(dj,songID)
